
#include <iostream>

using namespace std;

class data_t
{
public:
    void init(data_t &dt);
    void myprintf(data_t &dt);
    bool isleap_year(data_t &dt);

private:
    int year;
    int month;
    int day;
};

void data_t::init(data_t & dt)
{
    cout<<"year  month  day"<<endl;
    cin>>dt.year>>dt.month>>dt.day;
}

void data_t::myprintf(data_t & dt)
{
    cout<<"year month day"<<endl;
    cout<<dt.year<<":"<<dt.month<<":"<<dt.day<<endl;
}

bool data_t::isleap_year(data_t & dt)
{
    if((dt.year%4 == 0 && dt.year%100 != 0) || (dt.year%400 == 0))
        return true;
    else
        return false;
}

int main(void)
{
    data_t da;

    da.init(da);
    da.myprintf(da);

    if(da.isleap_year(da))
        cout<<"leap year..."<<endl;
    else
        cout<<"not leap year..."<<endl;

    return 0;
}

